import Vue from 'vue'
import VueRouter from 'vue-router'
import {register} from './register.js'
import {forgetpassword} from './forgetpassword.js'
import {shoppingcart} from './shoppingcart.js'
import {settlement} from './settlement.js'
import {payment} from "./payment.js"
Vue.use(VueRouter)

const routes = [
  {
    path: '/',
    name: 'login',
    component: () =>import('../views/login/Login.vue')
  },
  ...register,
  ...forgetpassword,
  ...shoppingcart,
  ...settlement,
  ...payment,
  {
    path: '/useragreement',
    name: 'useragreement',
    component: () =>import('../views/login/User-agreement.vue')
  },
  {
    path:'/dialog',
    component:()=>import('../components/dialog.vue')
  }

]

const router = new VueRouter({
  routes
})

export default router
